package com.aurifa.struts2.plugin.image.views;

import java.util.Arrays;
import java.util.List;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.apache.struts2.views.TagLibrary;

import com.aurifa.struts2.plugin.image.component.ImageDirective;
import com.aurifa.struts2.plugin.image.component.ImageModel;
import com.opensymphony.xwork2.util.ValueStack;

public class ImageTagLibrary implements TagLibrary{
	
	public Object getFreemarkerModels(ValueStack stack,
	        HttpServletRequest req, HttpServletResponse res) {
	        return new ImageModel(stack, req, res);
	    }

	    public List<Class> getVelocityDirectiveClasses() {
	        Class[] directives = new Class[] {
	            ImageDirective.class
	        };
	        return Arrays.asList(directives);
	    }
}
